package com.MRYIN.serviceImpl;

import com.MRYIN.mapper.PaymentsMapper;
import com.MRYIN.pojo.Payments;
import com.MRYIN.service.PaymentsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @program: SHYC_03
 * @description: 款项业务层的实现类
 * @author: Mr.YIN
 * @create: 2021-02-25 13:43
 **/
@Service
public class PaymentsServiceImpl implements PaymentsService {

    @Autowired
    private PaymentsMapper paymentsMapper;

    @Override
    public int insertPayment(Payments payments) {

        return paymentsMapper.insertPayment(payments);
    }

    @Override
    public List<Payments> queryAllPayments() {
        return paymentsMapper.queryAllPayments();
    }

    @Override
    public List<Payments> queryAllPaymentsByPAY_PRJCODE(String PAY_PRJCODE) {
        return paymentsMapper.queryAllPaymentsByPAY_PRJCODE(PAY_PRJCODE);
    }

    @Override
    public List<Payments> queryAllPaymentsByPAY_NAME(String PAY_NAME) {
        return paymentsMapper.queryAllPaymentsByPAY_NAME(PAY_NAME);
    }

    @Override
    public List<Payments> queryAllPaymentsByPAY_CODEOrPAY_PRJCODE(String PAY_CODE, String PAY_PRJCODE) {
        return paymentsMapper.queryAllPaymentsByPAY_CODEOrPAY_PRJCODE(PAY_CODE,PAY_PRJCODE);
    }
}
